Previous Book Contents Book Index Next

Inside Macintosh: AppleScript Finder Guide /
Chapter 3 - Finder Commands / Command Definitions


Select

The Select command is a request to select one or more objects. If you specify objects in several containers, only the objects in the last specified container
will remain selected. The container must be open for the specified object to
be selected.

SYNTAX
select referenceToObject
PARAMETER
referenceToObject
A reference to the object or objects to be selected.
Class: Reference or list of references
RESULT
Reference to the selected object or a list of references.

EXAMPLE
This script selects two files in a single folder:

tell application "Finder"   select {file "To Tom" in folder "Letters" of startup disk, ¬
      file "To Lorraine" in folder "Letters" of startup disk}
end tell
The folder must be open for the script to work correctly.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
13 JUL 1996